package com.kaoshi.myweb.web.repository;

import java.util.List;
import java.util.Map;

import com.kaoshi.myweb.common.seachable.QueryCondition;
import com.kaoshi.myweb.web.entity.User;
import com.kaoshi.myweb.web.repository.core.GenericDao;
import com.kaoshi.myweb.web.repository.core.annotation.MyBatisRepository;


/**
 * 通过@MapperScannerConfigurer扫描目录中的所有接口, 动态在Spring Context中生成实现.
 * 方法名称必须与Mapper.xml中保持一致.
 * com.kaoshi.myweb.web.repository.UserDao
 * @author calvin
 */
@MyBatisRepository
public interface UserDao extends GenericDao<User, Long> {
	List<User> search(Map<String, Object> parameters);
	
	User findByName(String name);

	User findByLoginName(String loginName);
	
	List<User> getAllUsers();
	
	List<User> queryUsers(QueryCondition condition);
}
